<!DOCTYPE html>
<html lang="">
<head>
  <meta charset="utf-8">
  <title>测试框架</title>
  <!-- 引入vue -->
  <script type = "text/javascript" src="../../../public/js/vue.min.js"></script>
</head>
<body>
<div id="root">
  单向数据绑定：<input type="text" v-bind:value = "name">
  <hr>
  <!-- v-model只能应用于表单输入类元素上 -->
  双向数据绑定:<input type="text" v-model:value = "title">
  <hr>
  双向数据绑定简写:<input type="text" v-model = "title2">
</div>
<script type = "text/javascript">
    const phpData = <?php echo $view_data; ?>;
    const dataArr = phpData.content;

    Vue.config.productionTip = false
    //创建vue对象
    new Vue({
      el:'#root',
      data:dataArr,
      // {
      //   name:phpData.content.name,
      //   title:phpData.content.title,
      //   title2:phpData.content.title2
      // },
    })
</script>
</body>
</html>